import store from '@/store'
import Img from '@/assets/common/head.jpg'
export const imgError = {
  inserted(dom, binding) {
    // console.log(dom, binding.value)
    dom.onerror = () => {
      dom.src = binding.value || Img
    }
  }
}
export const allow = {
  inserted(dom, binding) {
    const isPoint = store.getters.points.includes(binding.value)
    if (!isPoint) dom.style.display = 'none'
  }
}
